package com.yinian.server.controller;

import com.yinian.common.result.Result;
import com.yinian.pojo.dto.OperaVideoDTO;
import com.yinian.pojo.vo.OperaVideoVO;
import com.yinian.server.service.OperaService;
import io.swagger.annotations.Api;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;

@RestController
@Slf4j
@Api(tags = "返回戏曲视频")
public class OperaController {
    @Autowired
    private OperaService operaService;
   @PostMapping("/opera")
    public Result<List<OperaVideoVO>> getOperaVideo(@RequestBody OperaVideoDTO operaVideoDTO)
    {
        log.info("返回戏曲视频");
        return Result.success(operaService.getOperaVideo(operaVideoDTO));
    }
}
